(function(doc,win){
    rese = function(){
        var deviceWidth = doc.documentElement.clientWidth;
            var scale = deviceWidth / 640;
            if(deviceWidth >= 640){
                doc.documentElement.style.fontSize = '100px';
            }else{
                doc.documentElement.style.fontSize = scale * 100 + 'px';
            }
        }
            if(!doc.addEventListener){
                return;
            }
            doc.addEventListener('DOMContentLoaded',rese,false);
            win.addEventListener('resize',rese,false);
 } )(document,window)